<?php
/**
 * Created by JetBrains PhpStorm.
 * File: UserViewModel.class.php
 * User: Xnfy520@gmail.com
 * Date: 12-3-15
 * Time: 上午1:56
 */

	class UserViewModel extends ViewModel{

		public $viewFields = array(
			'User'=>array('id', 'username', 'nickname', 'email', 'active', 'reg_ip', 'reg_date', 'last_login_date', 'last_login_ip'),
			'RoleUser'=>array('role_id', '_on'=>'User.id=RoleUser.user_id'),
			'Role'=>array('name'=>'rolename','_on'=>'Role.id=RoleUser.role_id'),
		);

	}